Skip to content

fix bug where directory target were not handled according to the specification#794

Closed
Martin Torp (mtorp) wants to merge 4 commits intomainfrom
directory-target-fix
Closed

fix bug where directory target were not handled according to the specification#794
Martin Torp (mtorp) wants to merge 4 commits intomainfrom
directory-target-fix

Conversation

@mtorp
Copy link
Copy Markdown
Contributor

@mtorp Martin Torp (mtorp) commented Oct 16, 2025

Running something like socket scan create ./path/to/some/folder/with/manifests previously resulted in the error:

✖  Input error:  Please review the input requirements and try again

  ✖ TARGET (file/dir) must contain matching / supported file types for a scan (found no eligible files to scan. See supported manifest files at docs.socket.dev (​https://docs.socket.dev/docs/manifest-file-detection-in-socket​))

But the help menu specification for target includes: If it is a dir, the dir is scanned for any supported manifest files. I've updated glob.mts such that it now behaves according to the specification.

John-David Dalton (jdalton) added a commit that referenced this pull request Oct 22, 2025
When a directory path is provided, it now recursively scans that
directory for all files by appending /**/* to the path pattern.
This ensures directory targets work as expected in scanning operations.

Also fixes a type annotation issue in getWorkspaceGlobs.

Cherry-picked from PR #794 (commit 5f78dfd)
Original author: Martin Torp <martin@socket.dev>

Co-Authored-By: Martin Torp <martin@socket.dev>
@jdalton
Copy link
Copy Markdown
Contributor

Merging in manually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants